-- GENERATED SPELL FOR [First Mate Snellig] --


function spell0_1159(pUnit, Event) --@Curse of the Eye,n/a--
pUnit:FullCastSpellOnTarget(3360,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_1159', 622, 1)
end

function spell1_1159(pUnit, Event) --@Curse of the Eye,n/a--
pUnit:FullCastSpellOnTarget(10651,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_1159', 651, 1)
end

function spell2_1159(pUnit, Event) --@Curse of the Eye,n/a--
pUnit:FullCastSpellOnTarget(10653,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_1159', 597, 1)
end

function spell3_1159(pUnit, Event) --@Disarm,n/a--
pUnit:FullCastSpellOnTarget(6713,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_1159', 5265, 1)
end

function Sorts_1159(pUnit, Event)
local choix_sorts_1159 = math.random(0, 3)
if choix_sorts_1159 == 0 then
pUnit:RegisterEvent('spell0_1159', 1, 1)
end
if choix_sorts_1159 == 1 then
pUnit:RegisterEvent('spell1_1159', 1, 1)
end
if choix_sorts_1159 == 2 then
pUnit:RegisterEvent('spell2_1159', 1, 1)
end
if choix_sorts_1159 == 3 then
pUnit:RegisterEvent('spell3_1159', 1, 1)
end
end

function mob1159_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_1159', math.random(1500, 3000), 1)
end

function mob1159_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob1159_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob1159_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(1159, 1, 'mob1159_Action')
RegisterUnitEvent(1159, 2, 'mob1159_Leave')
RegisterUnitEvent(1159, 3, 'mob1159_Kill')
RegisterUnitEvent(1159, 4, 'mob1159_Die')
